package com.dnjn.happiness.emo.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.dnjn.happiness.common.core.annotation.Excel;
import com.dnjn.happiness.common.core.web.domain.BaseEntity;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;
import lombok.experimental.Accessors;

import java.math.BigDecimal;

/**
 * 消费记录对象 emo_user_record_pos
 * 
 * @author happiness
 * @date 2024-03-13
 */
@Schema(name = "EmoUserRecordPos", description = "消费记录")
@Accessors(chain = true)
@Getter
@Setter
@ToString
@TableName("emo_user_record_pos")
public class EmoUserRecordPos extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** PK */
    @JsonSerialize(using = ToStringSerializer.class)
    @TableId(value = "id", type = IdType.ASSIGN_ID)
    private Long id;

    /** sys_user.user_id */
    @Schema(description = "sys_user.user_id")
    @Excel(name = "sys_user.user_id")
    private Long userId;

    /** 人员编号 */
    @Schema(description = "人员编号")
    @Excel(name = "人员编号")
    private String empno;

    /** 订单号 */
    @Schema(description = "订单号")
    @Excel(name = "订单号")
    private String uniqueID;

    /** 卡号 */
    @Schema(description = "卡号")
    @Excel(name = "卡号")
    private String cardID;

    /** 钱包 */
    @Schema(description = "钱包")
    @Excel(name = "钱包")
    private String secID;

    /** 商户ID */
    @Schema(description = "商户ID")
    @Excel(name = "商户ID")
    private String bizOrgID;

    /** 商户名称（消费地点） */
    @Schema(description = "商户名称")
    @Excel(name = "商户名称", readConverterExp = "消=费地点")
    private String bizOrgName;

    /** 设备ID */
    @Schema(description = "设备ID")
    @Excel(name = "设备ID")
    private String devID;

    /** 餐段 eg. 午段 */
    @Schema(description = "餐段 eg. 午段")
    @Excel(name = "餐段 eg. 午段")
    private String mealTypeName;

    /** 消费时间 */
    @Schema(description = "消费时间")
//    @JsonFormat(pattern = "yyyy/MM/dd HH:mm:ss")
//    @JsonSerialize(using = LocalDateTimeSerializer.class)
//    @JsonDeserialize(using = LocalDateTimeDeserializer.class)
//    @Excel(name = "消费时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    private String posDay;

    /** 消费金额 */
    @Schema(description = "消费金额")
    @Excel(name = "消费金额")
    private BigDecimal posMoney;

    /** 消费后余额 */
    @Schema(description = "消费后余额")
    @Excel(name = "消费后余额")
    private BigDecimal balance;

    /** 是否删除|0-否 1-是 */
    private String deleted;

    




}
